

#ifndef _AbstractGeometryData_H_
#define _AbstractGeometryData_H_

#include "CoreApi.hpp"
#include "AbstractObject.hpp"
#include "AbstractGeometry.hpp"

#include <QList>
#include <QMap>
#include <vtkPoints.h>
#include <vtkPolyData.h>
#include <vtkSmartPointer.h>
#include <vtkAppendPolyData.h>
#include <vtkPolyDataNormals.h>

#include <TopoDS_Shape.hxx>


namespace NSCore {

	class COREAPI AbstractGeometryData : public AbstractObject {

	public:
		AbstractGeometryData();
		virtual ~AbstractGeometryData();

	public:
		virtual int addGeometryRaw(int id, QList<int>& ids, Sp(vtkPolyData) raw, TopoDS_Shape tp);
		virtual AbstractGeometry* getGeometryRaw(int id);
		virtual void clearGeometryRaw();
		virtual QPair<Sp(vtkPolyData), TopoDS_Shape> getGeometryPart();
		virtual void setGeometryPart(TopoDS_Shape topo);
		virtual Sp(vtkPolyData) normal_data(Sp(vtkPolyData) data);
		virtual int getId(int cellid);
		virtual void mapId(int key_id, int value_id); 
		virtual void setIsFace(bool face);
		virtual void updateGeometry(TopoDS_Shape tp);

	public:
		virtual inline QString className() override { return "AbstractGeometryData"; };
	protected:
		bool m_is_face{ false };
		int m_geom_type{ 0 }; 
		QMap<int, int> m_id_map;
		QList<NSCore::AbstractGeometry*> m_geoms;
		Sp(vtkAppendPolyData) m_part {nullptr};
		TopoDS_Shape m_shape;

	private:




	};


}

#endif